<?php

namespace App\Model;

use Illuminate\Database\Eloquent\Model;

class HomeUserModel extends Model
{
    protected $table = 'shop_home_users';

    // 一对一
    public function scores()
    {
        return $this->hasOne('App\Model\HomeUserScores', 'user_id');
    }

    // 一对多
    public function beforpass()
    {
        return $this->hasMany('App\Model\HomeUserBeforpass', 'user_id');
    }

    // 一对多
    public function address()
    {
        return $this->hasMany('App\Model\HomeUserAddress', 'user_id');
    }
}
